﻿<UserControl x:Class="EQual.MainModule.Projects.DetailsViews.ProjectDetailsView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:dg="http://schemas.microsoft.com/wpf/2008/toolkit" 
    xmlns:Models="clr-namespace:EQual.MainModule" 
    Height="200" Width="662">
    <UserControl.Resources >
        <!---->  
        <ObjectDataProvider x:Key="ProjectTypes" ObjectType="{x:Type Models:ProjectsProvider}" MethodName="GetProjectsTypes" />
        <ObjectDataProvider x:Key="ProjectStatusTypes" ObjectType="{x:Type Models:ProjectsProvider}" MethodName="GetProjectsStatusTypes" />
        <ObjectDataProvider x:Key="Employees" ObjectType="{x:Type Models:EmployeesProvider}" MethodName="GetEmployees" />
        
    </UserControl.Resources>
    <Grid  Height="199" Width="646">
        
        <TextBox Text="{Binding Path=SelectedItem.ProjectId}"  Height="23" HorizontalAlignment="Left" Margin="10,44,0,0" Name="textBox1" VerticalAlignment="Top" Width="120" />
        <Label Height="28" HorizontalAlignment="Left" Margin="10,10,0,0" Name="label1" VerticalAlignment="Top" Width="120">Project Id</Label>
        <TextBox Text="{Binding Path=SelectedItem.Title}"  Height="23" HorizontalAlignment="Left" Margin="170,44,0,0" Name="textBox2" VerticalAlignment="Top" Width="120" />
        <Label Height="28" HorizontalAlignment="Left" Margin="170,10,0,0" Name="label2" VerticalAlignment="Top" Width="120">Title</Label>
        <Label Height="28" Margin="12,0,0,42" Name="label3" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="120">Label</Label>
        <Label Height="28" HorizontalAlignment="Left" Margin="170,0,0,42" Name="label4" VerticalAlignment="Bottom" Width="120">Label</Label>
        <dg:DatePicker SelectedDate="{Binding Path=SelectedItem.StartDate}" Margin="12,0,0,12" Height="24" VerticalAlignment="Bottom"  HorizontalAlignment="Left" Width="144"/>
        <dg:DatePicker SelectedDate="{Binding Path=SelectedItem.EndDate}" Height="24"  Margin="170,0,0,12" VerticalAlignment="Bottom"   HorizontalAlignment="Left" Width="144"/>
        <ProgressBar Value="{Binding Path=SelectedItem.ProjectProgress}" HorizontalAlignment="Right" Margin="0,0,192,12" Name="progressBar1" Width="118"  Height="10" VerticalAlignment="Bottom"/>
        <Label  HorizontalAlignment="Right" Margin="0,0,190,42" Name="label5"  Width="120" Height="27" VerticalAlignment="Bottom">Project Progress</Label>
        
      
        
                <ComboBox                  SelectedValue="{Binding Path=SelectedItem.Employee}"         
                                           DisplayMemberPath="name"
                                           ItemsSource="{Binding Source={StaticResource Employees}}"
            Height="23" HorizontalAlignment="Right" Margin="0,44,190,0" Name="comboBox1" VerticalAlignment="Top" Width="120"  SelectionChanged="comboBox1_SelectionChanged"/>
        
        <Label Height="28" HorizontalAlignment="Right" Margin="0,10,190,0" Name="label6" VerticalAlignment="Top" Width="120">Project Owner</Label>
        <TextBox Height="23" HorizontalAlignment="Left" Margin="10,0,0,72" Name="textBox3" Text="{Binding  Path=SelectedItem.Employee.name}" VerticalAlignment="Bottom" Width="120" IsEnabled="False" />
        <Label Height="28" HorizontalAlignment="Left" Margin="10,70,0,0" Name="label7" VerticalAlignment="Top" Width="120">Name</Label>
        <TextBox Height="23" HorizontalAlignment="Left" Margin="170,0,0,72" Name="textBox4" Text="{Binding Path=SelectedItem.Employee.surname}" VerticalAlignment="Bottom" Width="120" IsEnabled="False"  />
        <Label Height="28" HorizontalAlignment="Left" Margin="170,70,0,0" Name="label8" VerticalAlignment="Top" Width="120">SurName</Label>

    </Grid>
</UserControl>
